/*
 *************************************************************************
 * The contents of this file are subject to the Openbravo  Public  License
 * Version  1.1  (the  "License"),  being   the  Mozilla   Public  License
 * Version 1.1  with a permitted attribution clause; you may not  use this
 * file except in compliance with the License. You  may  obtain  a copy of
 * the License at http://www.openbravo.com/legal/license.html
 * Software distributed under the License  is  distributed  on  an "AS IS"
 * basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the
 * License for the specific  language  governing  rights  and  limitations
 * under the License.
 * The Original Code is Openbravo ERP.
 * The Initial Developer of the Original Code is Openbravo SLU
 * All portions are Copyright (C) 2008-2014 Openbravo SLU
 * All Rights Reserved.
 * Contributor(s):  ______________________________________.
 ************************************************************************
*/
package com.eam.data;

import java.math.BigDecimal;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;

import org.openbravo.base.structure.ActiveEnabled;
import org.openbravo.base.structure.BaseOBObject;
import org.openbravo.base.structure.ClientEnabled;
import org.openbravo.base.structure.OrganizationEnabled;
import org.openbravo.base.structure.Traceable;
import org.openbravo.model.ad.access.User;
import org.openbravo.model.ad.system.Client;
import org.openbravo.model.common.enterprise.Organization;
/**
 * Entity class for entity Eam_Maintain_Plan (stored in table Eam_Maintain_Plan).
 *
 * NOTE: This class should not be instantiated directly. To instantiate this
 * class the {@link org.openbravo.base.provider.OBProvider} should be used.
 */
public class EamMaintainPlan extends BaseOBObject implements Traceable, ClientEnabled, OrganizationEnabled, ActiveEnabled {
    private static final long serialVersionUID = 1L;
    public static final String TABLE_NAME = "Eam_Maintain_Plan";
    public static final String ENTITY_NAME = "Eam_Maintain_Plan";
    public static final String PROPERTY_ID = "id";
    public static final String PROPERTY_USER = "user";
    public static final String PROPERTY_NAME = "name";
    public static final String PROPERTY_CODE = "code";
    public static final String PROPERTY_STARTDATE = "startDate";
    public static final String PROPERTY_ENDDATE = "endDate";
    public static final String PROPERTY_STATUS = "status";
    public static final String PROPERTY_PLANLVL = "planLvl";
    public static final String PROPERTY_ORGANIZATION = "organization";
    public static final String PROPERTY_CLIENT = "client";
    public static final String PROPERTY_ACTIVE = "active";
    public static final String PROPERTY_CREATIONDATE = "creationDate";
    public static final String PROPERTY_CREATEDBY = "createdBy";
    public static final String PROPERTY_UPDATED = "updated";
    public static final String PROPERTY_UPDATEDBY = "updatedBy";
    public static final String PROPERTY_MAINTAINBTN = "maintainBtn";
    public static final String PROPERTY_APPLYBTN = "applyBtn";
    public static final String PROPERTY_TYPE = "type";
    public static final String PROPERTY_EAMFAULTTYPE = "eamFaultType";
    public static final String PROPERTY_DISTINGUISH = "distinguish";
    public static final String PROPERTY_REMARKS = "remarks";
    public static final String PROPERTY_REPAIRBUTTON = "repairButton";
    public static final String PROPERTY_IMPORTBUTTON = "importButton";
    public static final String PROPERTY_SPARECODE = "spareCode";
    public static final String PROPERTY_PLANSTATETIME = "planStateTime";
    public static final String PROPERTY_PLANENDTIME = "planEndTime";
    public static final String PROPERTY_LENGTHTIME = "lengthTime";
    public static final String PROPERTY_PLANTYPE = "planType";
    public static final String PROPERTY_PREWARNINGTIME = "prewarningTime";
    public static final String PROPERTY_MSGSTATUS = "msgStatus";
    public static final String PROPERTY_EAMFACILITIESMTLOGSLIST = "eamFacilitiesMTLogsList";
    public static final String PROPERTY_EAMMAINTAINPLANFACSLIST = "eamMaintainPlanFacsList";

    public EamMaintainPlan() {
        setDefaultValue(PROPERTY_STATUS, "CREATE");
        setDefaultValue(PROPERTY_ACTIVE, true);
        setDefaultValue(PROPERTY_MAINTAINBTN, false);
        setDefaultValue(PROPERTY_APPLYBTN, false);
        setDefaultValue(PROPERTY_REPAIRBUTTON, false);
        setDefaultValue(PROPERTY_IMPORTBUTTON, false);
        setDefaultValue(PROPERTY_MSGSTATUS, false);
        setDefaultValue(PROPERTY_EAMFACILITIESMTLOGSLIST, new ArrayList<Object>());
        setDefaultValue(PROPERTY_EAMMAINTAINPLANFACSLIST, new ArrayList<Object>());
    }

    @Override
    public String getEntityName() {
        return ENTITY_NAME;
    }

    public String getId() {
        return (String) get(PROPERTY_ID);
    }

    public void setId(String id) {
        set(PROPERTY_ID, id);
    }

    public User getUser() {
        return (User) get(PROPERTY_USER);
    }

    public void setUser(User user) {
        set(PROPERTY_USER, user);
    }

    public String getName() {
        return (String) get(PROPERTY_NAME);
    }

    public void setName(String name) {
        set(PROPERTY_NAME, name);
    }

    public String getCode() {
        return (String) get(PROPERTY_CODE);
    }

    public void setCode(String code) {
        set(PROPERTY_CODE, code);
    }

    public Date getStartDate() {
        return (Date) get(PROPERTY_STARTDATE);
    }

    public void setStartDate(Date startDate) {
        set(PROPERTY_STARTDATE, startDate);
    }

    public Date getEndDate() {
        return (Date) get(PROPERTY_ENDDATE);
    }

    public void setEndDate(Date endDate) {
        set(PROPERTY_ENDDATE, endDate);
    }

    public String getStatus() {
        return (String) get(PROPERTY_STATUS);
    }

    public void setStatus(String status) {
        set(PROPERTY_STATUS, status);
    }

    public String getPlanLvl() {
        return (String) get(PROPERTY_PLANLVL);
    }

    public void setPlanLvl(String planLvl) {
        set(PROPERTY_PLANLVL, planLvl);
    }

    public Organization getOrganization() {
        return (Organization) get(PROPERTY_ORGANIZATION);
    }

    public void setOrganization(Organization organization) {
        set(PROPERTY_ORGANIZATION, organization);
    }

    public Client getClient() {
        return (Client) get(PROPERTY_CLIENT);
    }

    public void setClient(Client client) {
        set(PROPERTY_CLIENT, client);
    }

    public Boolean isActive() {
        return (Boolean) get(PROPERTY_ACTIVE);
    }

    public void setActive(Boolean active) {
        set(PROPERTY_ACTIVE, active);
    }

    public Date getCreationDate() {
        return (Date) get(PROPERTY_CREATIONDATE);
    }

    public void setCreationDate(Date creationDate) {
        set(PROPERTY_CREATIONDATE, creationDate);
    }

    public User getCreatedBy() {
        return (User) get(PROPERTY_CREATEDBY);
    }

    public void setCreatedBy(User createdBy) {
        set(PROPERTY_CREATEDBY, createdBy);
    }

    public Date getUpdated() {
        return (Date) get(PROPERTY_UPDATED);
    }

    public void setUpdated(Date updated) {
        set(PROPERTY_UPDATED, updated);
    }

    public User getUpdatedBy() {
        return (User) get(PROPERTY_UPDATEDBY);
    }

    public void setUpdatedBy(User updatedBy) {
        set(PROPERTY_UPDATEDBY, updatedBy);
    }

    public Boolean isMaintainBtn() {
        return (Boolean) get(PROPERTY_MAINTAINBTN);
    }

    public void setMaintainBtn(Boolean maintainBtn) {
        set(PROPERTY_MAINTAINBTN, maintainBtn);
    }

    public Boolean isApplyBtn() {
        return (Boolean) get(PROPERTY_APPLYBTN);
    }

    public void setApplyBtn(Boolean applyBtn) {
        set(PROPERTY_APPLYBTN, applyBtn);
    }

    public String getType() {
        return (String) get(PROPERTY_TYPE);
    }

    public void setType(String type) {
        set(PROPERTY_TYPE, type);
    }

    public EamFaultType getEamFaultType() {
        return (EamFaultType) get(PROPERTY_EAMFAULTTYPE);
    }

    public void setEamFaultType(EamFaultType eamFaultType) {
        set(PROPERTY_EAMFAULTTYPE, eamFaultType);
    }

    public String getDistinguish() {
        return (String) get(PROPERTY_DISTINGUISH);
    }

    public void setDistinguish(String distinguish) {
        set(PROPERTY_DISTINGUISH, distinguish);
    }

    public String getRemarks() {
        return (String) get(PROPERTY_REMARKS);
    }

    public void setRemarks(String remarks) {
        set(PROPERTY_REMARKS, remarks);
    }

    public Boolean isRepairButton() {
        return (Boolean) get(PROPERTY_REPAIRBUTTON);
    }

    public void setRepairButton(Boolean repairButton) {
        set(PROPERTY_REPAIRBUTTON, repairButton);
    }

    public Boolean isImportButton() {
        return (Boolean) get(PROPERTY_IMPORTBUTTON);
    }

    public void setImportButton(Boolean importButton) {
        set(PROPERTY_IMPORTBUTTON, importButton);
    }

    public String getSpareCode() {
        return (String) get(PROPERTY_SPARECODE);
    }

    public void setSpareCode(String spareCode) {
        set(PROPERTY_SPARECODE, spareCode);
    }

    public Date getPlanStateTime() {
        return (Date) get(PROPERTY_PLANSTATETIME);
    }

    public void setPlanStateTime(Date planStateTime) {
        set(PROPERTY_PLANSTATETIME, planStateTime);
    }

    public Date getPlanEndTime() {
        return (Date) get(PROPERTY_PLANENDTIME);
    }

    public void setPlanEndTime(Date planEndTime) {
        set(PROPERTY_PLANENDTIME, planEndTime);
    }

    public String getLengthTime() {
        return (String) get(PROPERTY_LENGTHTIME);
    }

    public void setLengthTime(String lengthTime) {
        set(PROPERTY_LENGTHTIME, lengthTime);
    }

    public String getPlanType() {
        return (String) get(PROPERTY_PLANTYPE);
    }

    public void setPlanType(String planType) {
        set(PROPERTY_PLANTYPE, planType);
    }

    public BigDecimal getPrewarningTime() {
        return (BigDecimal) get(PROPERTY_PREWARNINGTIME);
    }

    public void setPrewarningTime(BigDecimal prewarningTime) {
        set(PROPERTY_PREWARNINGTIME, prewarningTime);
    }

    public Boolean isMsgStatus() {
        return (Boolean) get(PROPERTY_MSGSTATUS);
    }

    public void setMsgStatus(Boolean msgStatus) {
        set(PROPERTY_MSGSTATUS, msgStatus);
    }

    @SuppressWarnings("unchecked")
    public List<EamFacilitiesMTLogs> getEamFacilitiesMTLogsList() {
      return (List<EamFacilitiesMTLogs>) get(PROPERTY_EAMFACILITIESMTLOGSLIST);
    }

    public void setEamFacilitiesMTLogsList(List<EamFacilitiesMTLogs> eamFacilitiesMTLogsList) {
        set(PROPERTY_EAMFACILITIESMTLOGSLIST, eamFacilitiesMTLogsList);
    }

    @SuppressWarnings("unchecked")
    public List<EamMaintainPlanFacs> getEamMaintainPlanFacsList() {
      return (List<EamMaintainPlanFacs>) get(PROPERTY_EAMMAINTAINPLANFACSLIST);
    }

    public void setEamMaintainPlanFacsList(List<EamMaintainPlanFacs> eamMaintainPlanFacsList) {
        set(PROPERTY_EAMMAINTAINPLANFACSLIST, eamMaintainPlanFacsList);
    }

}
